const mongoose = require("mongoose");

const orderGoodsSchema = new mongoose.Schema({
    shopsId:{
        type: mongoose.Schema.Types.ObjectId,    // 商店id
        ref: 'shopsModel'
    },
    goodId:{
        type: mongoose.Schema.Types.ObjectId,    // 所属订单的商品 id
        ref: 'goodsModel'
    },
    count: String, // 当前商品数量量
})

mongoose.model("orderGoodsModel", orderGoodsSchema, "orderGoods");